class NaviResp {
  List<NaviGroup> _data;
  int _errorCode;
  String _errorMsg;

  List<NaviGroup> get data => _data;

  int get errorCode => _errorCode;

  String get errorMsg => _errorMsg;

  NaviResp({List<NaviGroup> data, int errorCode, String errorMsg}) {
    _data = data;
    _errorCode = errorCode;
    _errorMsg = errorMsg;
  }

  NaviResp.fromJson(dynamic json) {
    if (json["data"] != null) {
      _data = [];
      json["data"].forEach((v) {
        _data.add(NaviGroup.fromJson(v));
      });
    }
    _errorCode = json["errorCode"];
    _errorMsg = json["errorMsg"];
  }

  Map<String, dynamic> toJson() {
    var map = <String, dynamic>{};
    if (_data != null) {
      map["data"] = _data.map((v) => v.toJson()).toList();
    }
    map["errorCode"] = _errorCode;
    map["errorMsg"] = _errorMsg;
    return map;
  }
}

class NaviGroup {
  List<NaviBean> _articles;
  String _name;
  int _cid;

  int get cid => _cid;

  List<NaviBean> get articles => _articles;

  String get name => _name;

  NaviGroup({List<NaviBean> articles, String name}) {
    _articles = articles;
    _name = name;
  }

  NaviGroup.fromJson(dynamic json) {
    if (json["articles"] != null) {
      _articles = [];
      json["articles"].forEach((v) {
        _articles.add(NaviBean.fromJson(v));
      });
    }
    _name = json["name"];
    _cid = json["cid"];
  }

  Map<String, dynamic> toJson() {
    var map = <String, dynamic>{};
    if (_articles != null) {
      map["articles"] = _articles.map((v) => v.toJson()).toList();
    }
    map["name"] = _name;
    map["cid"] = cid;
    return map;
  }
}

class NaviBean {
  int _id;
  String _title;

  String get title => _title;

  int get id => _id;

  NaviBean({int id, String title}) {
    _id = id;
    _title = title;
  }

  NaviBean.fromJson(dynamic json) {
    _id = json["id"];
    _title = json["title"];
  }

  Map<String, dynamic> toJson() {
    var map = <String, dynamic>{};
    map["id"] = _id;
    map["title"] = _title;
    return map;
  }
}
